RHINENG-26119: add support for publishing advisory update events#2224
Open
katarinazaprazna wants to merge 1 commit into
Open
RHINENG-26119: add support for publishing advisory update events#2224katarinazaprazna wants to merge 1 commit into
katarinazaprazna wants to merge 1 commit into
Conversation
Reviewer's GuideAdds feature-gated publishing of advisory update Kafka events during evaluation, wiring new configuration, topic handling, publisher, and tests for advisory deltas while keeping existing behavior unchanged. File-Level Changes
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
ed405ba to
312e979
Compare
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #2224 +/- ##
==========================================
+ Coverage 58.46% 58.56% +0.09%
==========================================
Files 139 140 +1
Lines 8925 8973 +48
==========================================
+ Hits 5218 5255 +37
- Misses 3159 3166 +7
- Partials 548 552 +4
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
Hey - I've left some high level feedback:
- The
createAdvisoryUpdateEventpath logs a warning for every system without workspaces ("no workspaces for system"), which might be noisy in environments where workspaces are not commonly set; consider downgrading this to debug or only logging when a workspace feature flag is enabled. - When workspace ID parsing fails in
createAdvisoryUpdateEvent, you currently emit a warning and send a zero UUID; it may be clearer to omit the workspace ID field (or keep it as a pointer/optional) so downstream consumers can distinguish between "missing" and "all-zero" values. publishAdvisoryUpdatessilently returns whenadvisoryUpdatePublisheris nil even ifenableAdvisoryUpdatesis true; consider logging once at startup or during configuration when the feature flag is enabled but no topic/publisher is configured to make misconfiguration easier to detect.
Prompt for AI Agents
Please address the comments from this code review:
## Overall Comments
- The `createAdvisoryUpdateEvent` path logs a warning for every system without workspaces (`"no workspaces for system"`), which might be noisy in environments where workspaces are not commonly set; consider downgrading this to debug or only logging when a workspace feature flag is enabled.
- When workspace ID parsing fails in `createAdvisoryUpdateEvent`, you currently emit a warning and send a zero UUID; it may be clearer to omit the workspace ID field (or keep it as a pointer/optional) so downstream consumers can distinguish between "missing" and "all-zero" values.
- `publishAdvisoryUpdates` silently returns when `advisoryUpdatePublisher` is nil even if `enableAdvisoryUpdates` is true; consider logging once at startup or during configuration when the feature flag is enabled but no topic/publisher is configured to make misconfiguration easier to detect.Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
patchman.advisory.updateKafka topic after each system evaluationJira ticket: https://redhat.atlassian.net/browse/RHINENG-26119
Secure Coding Practices Checklist GitHub Link
Secure Coding Checklist
Summary by Sourcery
Add support for emitting advisory update events during evaluation when advisories change and the feature is enabled.
New Features:
Enhancements:
Tests:
Summary by Sourcery
Add optional publishing of advisory update Kafka events during system evaluation when advisories change.
New Features:
Enhancements:
Tests: